package com.shilei.iterator.v3;



/**
 * @description:  实现数组接口 这样两个List可以互相替换
 *                实现遍历接口  可以进行遍历
 * @author: 81271
 * @date: 2020-04-19 20:13
 */
public class Main {
    public static void main(String[] args) {
        Collection_<String> collection_ = new LinkedList_<>();

        for (int i = 0; i < 15; i++) {
            collection_.add("i" + i);
        }
        System.out.println(collection_.size());

        Iterator_<String> iterator_ = collection_.iterator();
        while (iterator_.hasNext()) {
            String o = iterator_.next();
            System.out.println(o);
        }



    }
}
